<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Strict//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>libfanfou</title>
</head>
<body>
<?php
	require_once "Fanfou.class.php";
	
        $fanfou = new Fanfou("bbiao", "");
//	$fanfou->update("^_^");
	
	$userTimeline = $fanfou->userTimeline();
	$friendsTimeline = $fanfou->friendsTimeline();
	
	$friends = $fanfou->friends();
	$followers = $fanfou->followers();
	
	echo "<table><tbody>";
	foreach($userTimeline as $ut) {
		echo "<tr>";
			echo "<td><img src='{$ut->user->profile_image_url}'></img></td>";
			echo "<td><span>{$ut->text}</span></td>";
		echo "</tr>";
	}
	foreach($friendsTimeline as $ft) {
		echo "<tr>";
			echo "<td><img src='{$ft->profile_image_url}'></img></td>";
			echo "<td><span>{$ft->status->text}</span></td>";
		echo "</tr>";
	}
	
	foreach($friends as $f) {
		echo "<tr>";
			echo "<td><img src='{$f->profile_image_url}'></img></td>";
			echo "<td><span>{$f->name}</span><span>({$f->location})</span></td>";
		echo "</tr>";
	}
	
	foreach($followers as $f) {
		echo "<tr>";
			echo "<td><img src='{$f->profile_image_url}'></img></td>";
			echo "<td><span>{$f->name}</span><span>({$f->location})</span></td>";
		echo "</tr>";
	}
	echo "</tbody></table>";
?>

</body>
</html>
